var scroll_first;
var first;
var i=0

$(document).ready(function () {


    function moveDome() {
        first = $("#express li").first();
        first.animate({"margin-top": -first.height()}, 2000, "linear", function () {
            first.css("margin-top", 0).appendTo($("#express"));
            moveDome();
        });
    }

    moveDome();
    scroll_down()


    $("#express").hover(function () {
        first.stop();
//        clearTimeout(moveHandler);
    }, function () {
        moveDome();
    });
});

function scroll_down() {
    scroll_first = $("#scroll_img li").first();
    scroll_first.animate({"margin-top": -scroll_first.height()}, 800, "linear", function () {
        scroll_first.css("margin-top", 0).appendTo($("#scroll_img"));
        scroll_down()
        console.log(++i)
    });
}
$(document).keydown(function(e){
    console.log(e)
    if (e && e.keyCode == 9) { // 按 Esc
        scroll_first.css("margin-top",-scroll_first.height())
        console.log("tab")
    }
}
)